import React, { Suspense } from 'react';
import Footer from './layout/footer';
import Header from './layout/header';
// 使用路由
import { useRoutes } from 'react-router-dom';
import routes from './router';
import { AppWrapper } from './App.styled';

function App() {
    return (
        <AppWrapper>
            <Header></Header>
            <Suspense fallback="">{useRoutes(routes)}</Suspense>
            <Footer></Footer>
        </AppWrapper>
    );
}

export default App;
